<!DOCTYPE html>
<html>
<head>
    <title>{{ question.question_text }} Results</title>
    {% load static %}
    <link rel="stylesheet" href="{% static 'polls/css/results.css' %}">
</head>
<body>
    <header>
        <h1>{{ question.question_text }}</h1>
    </header>
    <main>
        <ul class="result-list">
        {% for choice in question.choice_set.all %}
            <li class="result-item">
                <span>{{ choice.choice_text }}</span>
                <span>{{ choice.votes }} vote{{ choice.votes|pluralize }}</span>
            </li>
        {% endfor %}
        </ul>
        <!-- 修改这里的url名称 -->
        <b><a href="{% url 'polls:index' %}">Back to Options</a></b>
        <h>/</h>
        <b><a href="{% url 'polls:detail' question.id %}">Vote again</a></b>
    </main>
    <footer>
        <p class="copy-right">&copy; 2024 MyPolls</p>
    </footer>
</body>
</html>